3.929 \(\int \frac{(a+b x)^n}{x^2 (c+d x)} \, dx\)

Optimal. Leaf size=124 \[ \frac{(a+b x)^{n+1} (a d-b c n) \, _2F_1\left (1,n+1;n+2;\frac{b x}{a}+1\right )}{a^2 c^2 (n+1)}+\frac{d^2 (a+b x)^{n+1} \, _2F_1\left (1,n+1;n+2;-\frac{d (a+b x)}{b c-a d}\right )}{c^2 (n+1) (b c-a d)}-\frac{(a+b x)^{n+1}}{a c x} \]

[Out]

-((a + b*x)^(1 + n)/(a*c*x)) + (d^2*(a + b*x)^(1 + n)*Hypergeometric2F1[1, 1 + n
, 2 + n, -((d*(a + b*x))/(b*c - a*d))])/(c^2*(b*c - a*d)*(1 + n)) + ((a*d - b*c*
n)*(a + b*x)^(1 + n)*Hypergeometric2F1[1, 1 + n, 2 + n, 1 + (b*x)/a])/(a^2*c^2*(
1 + n))

_______________________________________________________________________________________

Rubi [A]  time = 0.217021, antiderivative size = 124, normalized size of antiderivative = 1., number of steps used = 4, number of rules used = 4, integrand size = 18, \(\frac{\text{number of rules}}{\text{integrand size}}\) = 0.222 \[ \frac{(a+b x)^{n+1} (a d-b c n) \, _2F_1\left (1,n+1;n+2;\frac{b x}{a}+1\right )}{a^2 c^2 (n+1)}+\frac{d^2 (a+b x)^{n+1} \, _2F_1\left (1,n+1;n+2;-\frac{d (a+b x)}{b c-a d}\right )}{c^2 (n+1) (b c-a d)}-\frac{(a+b x)^{n+1}}{a c x} \]

Antiderivative was successfully verified.

[In]  Int[(a + b*x)^n/(x^2*(c + d*x)),x]

[Out]

-((a + b*x)^(1 + n)/(a*c*x)) + (d^2*(a + b*x)^(1 + n)*Hypergeometric2F1[1, 1 + n
, 2 + n, -((d*(a + b*x))/(b*c - a*d))])/(c^2*(b*c - a*d)*(1 + n)) + ((a*d - b*c*
n)*(a + b*x)^(1 + n)*Hypergeometric2F1[1, 1 + n, 2 + n, 1 + (b*x)/a])/(a^2*c^2*(
1 + n))

_______________________________________________________________________________________

Rubi in Sympy [A]  time = 39.5131, size = 95, normalized size = 0.77 \[ - \frac{d^{2} \left (a + b x\right )^{n + 1}{{}_{2}F_{1}\left (\begin{matrix} 1, n + 1 \\ n + 2 \end{matrix}\middle |{\frac{d \left (a + b x\right )}{a d - b c}} \right )}}{c^{2} \left (n + 1\right ) \left (a d - b c\right )} - \frac{\left (a + b x\right )^{n + 1}}{a c x} + \frac{\left (a + b x\right )^{n + 1} \left (a d - b c n\right ){{}_{2}F_{1}\left (\begin{matrix} 1, n + 1 \\ n + 2 \end{matrix}\middle |{1 + \frac{b x}{a}} \right )}}{a^{2} c^{2} \left (n + 1\right )} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]  rubi_integrate((b*x+a)**n/x**2/(d*x+c),x)

[Out]

-d**2*(a + b*x)**(n + 1)*hyper((1, n + 1), (n + 2,), d*(a + b*x)/(a*d - b*c))/(c
**2*(n + 1)*(a*d - b*c)) - (a + b*x)**(n + 1)/(a*c*x) + (a + b*x)**(n + 1)*(a*d
- b*c*n)*hyper((1, n + 1), (n + 2,), 1 + b*x/a)/(a**2*c**2*(n + 1))

_______________________________________________________________________________________

Mathematica [A]  time = 0.303852, size = 155, normalized size = 1.25 \[ \frac{(a+b x)^n \left (\frac{d \left (\left (\frac{d (a+b x)}{b (c+d x)}\right )^{-n} \, _2F_1\left (-n,-n;1-n;\frac{b c-a d}{b c+b d x}\right )-\left (\frac{a}{b x}+1\right )^{-n} \, _2F_1\left (-n,-n;1-n;-\frac{a}{b x}\right )\right )}{n}+\frac{c \left (\frac{a}{b x}+1\right )^{-n} \, _2F_1\left (1-n,-n;2-n;-\frac{a}{b x}\right )}{(n-1) x}\right )}{c^2} \]

Antiderivative was successfully verified.

[In]  Integrate[(a + b*x)^n/(x^2*(c + d*x)),x]

[Out]

((a + b*x)^n*((c*Hypergeometric2F1[1 - n, -n, 2 - n, -(a/(b*x))])/((-1 + n)*(1 +
 a/(b*x))^n*x) + (d*(-(Hypergeometric2F1[-n, -n, 1 - n, -(a/(b*x))]/(1 + a/(b*x)
)^n) + Hypergeometric2F1[-n, -n, 1 - n, (b*c - a*d)/(b*c + b*d*x)]/((d*(a + b*x)
)/(b*(c + d*x)))^n))/n))/c^2

_______________________________________________________________________________________

Maple [F]  time = 0.079, size = 0, normalized size = 0. \[ \int{\frac{ \left ( bx+a \right ) ^{n}}{{x}^{2} \left ( dx+c \right ) }}\, dx \]

Verification of antiderivative is not currently implemented for this CAS.

[In]  int((b*x+a)^n/x^2/(d*x+c),x)

[Out]

int((b*x+a)^n/x^2/(d*x+c),x)

_______________________________________________________________________________________

Maxima [F]  time = 0., size = 0, normalized size = 0. \[ \int \frac{{\left (b x + a\right )}^{n}}{{\left (d x + c\right )} x^{2}}\,{d x} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]  integrate((b*x + a)^n/((d*x + c)*x^2),x, algorithm="maxima")

[Out]

integrate((b*x + a)^n/((d*x + c)*x^2), x)

_______________________________________________________________________________________

Fricas [F]  time = 0., size = 0, normalized size = 0. \[{\rm integral}\left (\frac{{\left (b x + a\right )}^{n}}{d x^{3} + c x^{2}}, x\right ) \]

Verification of antiderivative is not currently implemented for this CAS.

[In]  integrate((b*x + a)^n/((d*x + c)*x^2),x, algorithm="fricas")

[Out]

integral((b*x + a)^n/(d*x^3 + c*x^2), x)

_______________________________________________________________________________________

Sympy [F]  time = 0., size = 0, normalized size = 0. \[ \int \frac{\left (a + b x\right )^{n}}{x^{2} \left (c + d x\right )}\, dx \]

Verification of antiderivative is not currently implemented for this CAS.

[In]  integrate((b*x+a)**n/x**2/(d*x+c),x)

[Out]

Integral((a + b*x)**n/(x**2*(c + d*x)), x)

_______________________________________________________________________________________

GIAC/XCAS [F]  time = 0., size = 0, normalized size = 0. \[ \int \frac{{\left (b x + a\right )}^{n}}{{\left (d x + c\right )} x^{2}}\,{d x} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]  integrate((b*x + a)^n/((d*x + c)*x^2),x, algorithm="giac")

[Out]

integrate((b*x + a)^n/((d*x + c)*x^2), x)